package ch6;

import java.util.Scanner;

public class ARr2 {

	public static void main(String[] args) {
		// zhijie fuzhi
		int[] ar = { 32, 56, 78 };
		System.out.println(ar[0] + "," + ar[2]);
		int[] ar2 = new int[] { 1, 2, 3, 4 };
		System.out.println(ar2[3]);
		// bixu yibu gaoding
		int[] a3;
		a3 = new int[] { 1, 2, 4, 5 };
		System.out.println(a3[2]);
		int a4[] = new int[10];
		Scanner in = new Scanner(System.in);
		System.out.println("please input numbers for array:");
		for (int i = 0; i < a4.length; i++) {
			a4[i] = in.nextInt();
		}
		System.out.println("You input is :");
		for (int i = 0; i < a4.length; i++) {
			System.out.print(a4[i] + "\t");
		}
	}

}
